package org.telegram.bot.domain;

import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;
import lombok.Data;
import lombok.experimental.Accessors;
import lombok.EqualsAndHashCode;
import com.baomidou.mybatisplus.annotation.*;

/**
 * 公共违禁词对象 bot_public_block
 *
 * @author wyx
 * @date 2024-11-27
 */
@Data
@Accessors(chain = true)
@EqualsAndHashCode(callSuper = true)
@TableName("bot_public_block")
public class BotPublicBlock extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** id */
    @TableId("id")
    @JsonSerialize(using = ToStringSerializer.class)
    private Long id;

    /** 违禁词 */
    @Excel(name = "违禁词")
    @TableField(value = "word", condition = SqlCondition.LIKE)
    private String word;

    /** 显示顺序 */
    private Integer orderNum;

    /** 状态（0正常 1停用） */
    @Excel(name = "状态", readConverterExp = "0=正常,1=停用")
    private String status;

    /** 删除标志（0代表存在 1代表删除） */
    private String delFlag;

    /** 创建者Id */
    @TableField(fill = FieldFill.INSERT)
    private Long createById;


    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("word", getWord())
            .append("remark", getRemark())
            .append("orderNum", getOrderNum())
            .append("status", getStatus())
            .append("delFlag", getDelFlag())
            .append("createBy", getCreateBy())
            .append("createById", getCreateById())
            .append("createTime", getCreateTime())
            .append("updateBy", getUpdateBy())
            .append("updateTime", getUpdateTime())
            .toString();
    }
}
